/**
 * @Author: Boring
 * @Description:
 * @File:  daemonset
 * @Date: 2024-03-02 14:50
 */

package daemonset

import (
	"github.com/gin-gonic/gin"
	"oam-manage-backend/controllers/daemonset"
)

func create(daemonsetGroup *gin.RouterGroup) {
	daemonsetGroup.POST("/create", daemonset.Create)
}

func update(daemonsetGroup *gin.RouterGroup) {
	daemonsetGroup.PUT("/update", daemonset.Update)
}

func delete(daemonsetGroup *gin.RouterGroup) {
	daemonsetGroup.DELETE("/delete", daemonset.Delete)
}

func deleteList(daemonsetGroup *gin.RouterGroup) {
	daemonsetGroup.POST("/deleteList", daemonset.DeleteList)
}

func get(daemonsetGroup *gin.RouterGroup) {
	daemonsetGroup.GET("/get", daemonset.Get)
}

func list(daemonsetGroup *gin.RouterGroup) {
	daemonsetGroup.GET("/list", daemonset.List)
}

func RegisterSubRouter(g *gin.RouterGroup) {
	daemonsetGroup := g.Group("/daemonset")
	create(daemonsetGroup)
	update(daemonsetGroup)
	delete(daemonsetGroup)
	deleteList(daemonsetGroup)
	get(daemonsetGroup)
	list(daemonsetGroup)
}
